﻿using Domain;
using Microsoft.EntityFrameworkCore;

namespace Infratructure
{
    /// <summary>
    /// 定义迁移实体
    /// </summary>
    public class MyDBcontext : DbContext
    {
        public MyDBcontext(DbContextOptions options) : base(options)
        {
        } 
        /// <summary>
        /// 用户实体
        /// </summary>
        public DbSet<UserModel> UserModel { get; set; }
        /// <summary>
        /// 用户实体
        /// </summary>
        public DbSet<RoleModel> RoleModel { get; set; }
        /// <summary>
        /// 用户角色中间表实体
        /// </summary>
        public DbSet<UserRoleModel> UserRoleModel { get; set; }
        /// <summary>
        /// 权限实体
        /// </summary>
        public DbSet<PermissionModel> PermissionModel { get; set; }
        /// <summary>
        /// 角色权限中间表实体
        /// </summary>
        public DbSet<RolePermissionModel> RolePermissionModel { get; set; }
    }
}
